home *** CD-ROM | disk | FTP | other *** search
- public class EffectDiscPrisonOfIce extends Codex {
- CodexActor target;
- boolean bIsNoFeed;
- boolean bIsNoBleed;
-
- public void EndEffect(int targetGuid) {
- CodexActor target = new CodexActor(targetGuid);
- ((CodexThing)target).UnfreezeAnimations();
- ((CodexThing)target).EndShell();
- if (!this.bIsNoFeed && !this.bIsNoBleed) {
- target.ClearActorFlags(24);
- } else {
- if (!this.bIsNoFeed) {
- target.ClearActorFlags(8);
- }
-
- if (!this.bIsNoBleed) {
- target.ClearActorFlags(16);
- }
- }
-
- }
-
- public void restore(int flags) {
- this.bIsNoFeed = CodexSequence.RestoreBoolean();
- this.bIsNoBleed = CodexSequence.RestoreBoolean();
- }
-
- public void effectstarted(int actorGuid, int effectGuid, int creatorGuid, int duration) {
- this.target = new CodexActor(actorGuid);
- this.target.SpawnThing("blueMagic");
- this.target.SetShell("iceShell", 4096, 0.0F, 0.3F, 1.0F, 1.0F);
- this.target.FreezeAnimations();
- this.bIsNoFeed = (this.target.GetActorFlags() & 8) != 0;
- this.bIsNoBleed = (this.target.GetActorFlags() & 16) != 0;
- this.target.SetActorFlags(24);
- ((Codex)this).CaptureThing(actorGuid);
- }
-
- public void killed(int guid, int causeID, int captureID) {
- this.EndEffect(guid);
- }
-
- public void save(int flags) {
- CodexSequence.SaveBoolean(this.bIsNoFeed);
- CodexSequence.SaveBoolean(this.bIsNoBleed);
- }
-
- public void effectended(int actorGuid, int effectGuid, int creatorGuid, int reason) {
- this.EndEffect(actorGuid);
- }
- }
-